<template>
    <div class="">
        <div>
            <van-list
                    v-model="config.loading"
                    :finished="config.finished"
                    finished-text="没有更多了"
                    @load="signs"
                    :immediate-check="false"
            >
                <div class="pd-12-16 border-bottom" v-for="(item,index) in list" :key="index">
                    <div class="flex-row justify-content-between align-items-center">
                        <div class="font-14">{{item.state_name}}</div>
                        <div class="font-grey">{{item.create}}</div>
                    </div>
<!--                    <div class="mt5 font-grey">{{item.remark}}</div>-->
                </div>
            </van-list>
        </div>
    </div>
</template>
<script>
    export default {
        name: "Signs",
        data() {
            return {
                list: [],
                url: {
                    signs: this.axiosUrl + 'users/signs'
                },
                config: {
                    loading: false,
                    finished: false,
                    pageIndex: 1,
                    limit: 10
                }
            }
        },
        components: {},
        mounted() {
            this.signs()
            this.$wxConfig.share(this.$route.path)

        },
        methods: {
            signs() {
                let _this = this
                _this.config.loading = true
                _this.$http.post(_this.url.signs, {
                    pages: _this.config.pageIndex,
                    limit: _this.config.limit
                }, (res) => {
                    _this.list = _this.list.concat(res)
                    _this.config.pageIndex++
                    if (res.length < _this.config.limit) {
                        _this.config.finished = true
                    } else {
                        _this.config.finished = false
                    }
                    _this.config.loading = false
                })
            }
        }
    }
</script>
<style lang="stylus" scoped>
    .van-tabs__line {
        background-color #ff6f00
    }

    .mine-list
        margin 16px
        background white
        border-radius 8px
        overflow hidden

</style>
